<template>
  <div class="hello">
    <h1>{{ msg }}</h1>
    <p>I AM P</p>
    <button @click="changeTheme('theme1')">切换theme1</button>
    <button @click="changeTheme('theme2')">切换theme2</button>
  </div>
</template>

<script>
export default {
  name: 'HelloWorld',
  props: {
    msg: String
  },
  methods: {
    changeTheme (key) {
      window.themeSetup(key);
    }
  }
}
</script>

<style scoped>
  button {
    padding: 10px 20px;
    margin: 2%;
  }
</style>
